﻿<Window x:Class="CoreRay.Client.PreviewWindow"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    Title="Core Ray - Preview Window" MinWidth="320" MinHeight="240" Height="768" Width="1024" WindowStartupLocation="CenterScreen" ResizeMode="CanResizeWithGrip">
    <DockPanel LastChildFill="True">
        <ToolBarTray DockPanel.Dock="Top">
            <ToolBar>
                <Button x:Name="saveButton" IsEnabled="False" Command="Save">
                    <Image Source="Resources\saveHS.png" Width="16" Height="16" />
                </Button>
                <Separator />
                <ToggleButton x:Name="moveButton" Checked="moveButton_Checked" Unchecked="moveButton_Unchecked">
                    <Image Source="Resources\CopyHS.png" Width="16" Height="16" />
                </ToggleButton>
                <ToggleButton x:Name="zoomButton" Checked="zoomButton_Checked" Unchecked="zoomButton_Unchecked">
                    <Image Source="Resources\ZoomHS.png" Width="16" Height="16" />
                </ToggleButton>
            </ToolBar>
        </ToolBarTray>
        <StatusBar DockPanel.Dock="Bottom">
            <StatusBarItem>
                <StackPanel Orientation="Horizontal">
                    <TextBlock x:Name="zoomTextBlock" VerticalAlignment="Center">100%</TextBlock>
                    <Slider x:Name="zoomSlider" Minimum="0.5" Maximum="4" Value="1" TickPlacement="BottomRight" LargeChange="0.5" TickFrequency="0.5" Width="150" ValueChanged="zoomSlider_ValueChanged" />
                </StackPanel>
            </StatusBarItem>
            <StatusBarItem HorizontalAlignment="Right" Padding="3 3 15 3">
                <TextBlock x:Name="informationText">Render done in 00:00:05.26500</TextBlock>
            </StatusBarItem>
        </StatusBar>
        <ScrollViewer VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto">
            <Canvas x:Name="mainCanvas" Background="Black" MouseMove="mainCanvas_MouseMove">
                <Canvas.LayoutTransform>
                    <ScaleTransform ScaleX="{Binding ElementName=zoomSlider, Path=Value}" ScaleY="{Binding ElementName=zoomSlider, Path=Value}" />
                </Canvas.LayoutTransform>
                <Image x:Name="previewImage" />
           </Canvas>
        </ScrollViewer>
    </DockPanel>
</Window>
